package me.yxy.mobanddd.domain.eventhandler;

import me.yxy.mobanddd.domain.events.TransportOrderModifiedEvent;
import org.springframework.context.ApplicationListener;
import org.springframework.stereotype.Component;

/**
 * 运单修改事件处理类
 */
@Component
public class TransportOrderModifiedEventHandler implements ApplicationListener<TransportOrderModifiedEvent> {

    @Override
    public void onApplicationEvent(TransportOrderModifiedEvent event) {

        //运单发生修改，可能影响的事情：

        //1. 运单归属的调度单的时间与总里程计算

        System.out.println("收到消息:"+event.getSource()+","+event.getTransportOrderId());


    }
}
